import request from '@/utils/request'
export function fetchList(params) {
  return request({
    url:'/admin/schedule/page',
    method:'get',
    params:params
  })
}
export function scheduleDetail(jobId) {
  return request({
    url:'/admin/schedule/info/'+jobId,
    method:'get'
  })
}
export function deleteSchedule(params) {
  return request({
    url:'/admin/schedule/delete',
    method:'post',
    data:params
  })
}
export function pauseSchedule(params) {
  return request({
    url:'/admin/schedule/pause',
    method:'post',
    data:params
  })
}
export function resumeSchedule(params) {
  return request({
    url:'/admin/schedule/resume',
    method:'post',
    data:params
  })
}
export function runSchedule(params) {
  return request({
    url:'/admin/schedule/run',
    method:'post',
    data:params
  })
}
export function addSchedule(params) {
  return request({
    url:'/admin/schedule/save',
    method:'post',
    data:params
  })
}
export function updateSchedule(params) {
  return request({
    url:'/admin/schedule/update',
    method:'post',
    data:params
  })
}
